package com.caicai.springbootrocketmq.consumer;

import org.apache.rocketmq.spring.core.RocketMQListener;
import org.springframework.stereotype.Component;

@Component
@ConsumerListener(topic = "TopicTestWarn", consumerGroupName = "warn_consumer_group")
public class WarnConsumer implements RocketMQListener<String> {
    @Override
    public void onMessage(String message) {
        System.out.println("预警消息消费：" + message);
    }
}